/
UserAuthenticatedEventArgs.cs
69 lines (57 loc) · 2.84 KB
/
UserAuthenticatedEventArgs.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information
namespace DotNetNuke.Services.Authentication
{
using System;
using System.Collections.Specialized;
using DotNetNuke.Entities.Users;
using DotNetNuke.Security.Membership;
/// <summary>
/// The UserAuthenticatedEventArgs class provides a custom EventArgs object for the
/// UserAuthenticated event.
/// </summary>
public class UserAuthenticatedEventArgs : EventArgs
{
/// <summary>
/// Initializes a new instance of the <see cref="UserAuthenticatedEventArgs"/> class.
/// All properties Constructor.
/// </summary>
/// <param name="user">The user being authenticated.</param>
/// <param name="token">The user token.</param>
/// <param name="status">The login status.</param>
/// <param name="type">The type of Authentication.</param>
public UserAuthenticatedEventArgs(UserInfo user, string token, UserLoginStatus status, string type)
{
this.Profile = new NameValueCollection();
this.Message = string.Empty;
this.AutoRegister = false;
this.Authenticated = true;
this.User = user;
this.LoginStatus = status;
this.UserToken = token;
this.AuthenticationType = type;
this.RememberMe = false;
}
/// <summary>Gets or sets a value indicating whether gets and sets a flag that determines whether the User was authenticated.</summary>
public bool Authenticated { get; set; }
/// <summary>Gets or sets the Authentication Type.</summary>
public string AuthenticationType { get; set; }
/// <summary>Gets or sets a value indicating whether gets and sets a flag that determines whether the user should be automatically registered.</summary>
public bool AutoRegister { get; set; }
/// <summary>Gets or sets the Login Status.</summary>
public UserLoginStatus LoginStatus { get; set; }
/// <summary>Gets or sets the Message.</summary>
public string Message { get; set; }
/// <summary>Gets or sets the Profile.</summary>
public NameValueCollection Profile { get; set; }
/// <summary>Gets or sets a value indicating whether gets and sets the RememberMe setting.</summary>
public bool RememberMe { get; set; }
/// <summary>Gets or sets the User.</summary>
public UserInfo User { get; set; }
/// <summary>Gets or sets the UserToken (the userid or authenticated id).</summary>
public string UserToken { get; set; }
/// <summary>Gets or sets the Username.</summary>
public string UserName { get; set; }
}
}